<!DOCTYPE html>
<html lang="en">
    <head>
        <meta charset="UTF-8">
        <title>Title</title>
        <style>
            div{
                width:100px;
                height:100px;
                border:1px solid red;
                padding:5px;

                /*
                    设置是否包含边框和内边距在内
                    取值:
                        content-box(默认值)、border-box(包含边框和内边距在内)
                */
                box-sizing:border-box;
            }
        </style>
    </head>
    <body>
        <div></div>
    </body>
</html>